<?php
	require '../biz/backend.php';

	class action extends backend
	{
		var $get_privilege_id = '86';


		function do_get()
		{
			$module_type = array( '1'=>'新闻', '2'=>'相片','3'=>'视频','4'=>'音乐','5'=>'FLASH','6'=>'软件','7'=>'商品' );
			$cate = load( 'biz.cate' );
			$this->input['size'] = ( isset( $this->input['size'] ) && $this->input['size'] !='' ) ? $this->input['size'] : '999';
			$this->input['module_type_id'] = ( isset( $_GET['module_type_id'] ) && preg_match( '!^\d+$!', $_GET['module_type_id'] ) ) ? $_GET['module_type_id'] : '';

			$data = $cate->all( $this->input );
			$cateTree = $cate->getcatelist($data['data']);
			//echo $this->input['module_type_id'];
			echo json_encode ( $cateTree );

		}
	}

	$action = new action();
	$action->run();
?>